//
//  OverlayViewController.h
//  POCRA
//
//  Created by Marcel Arbó Lack on 26/11/10.
//  Copyright 2010 Mobivery. All rights reserved.
//


#import <UIKit/UIKit.h>
#import "ARGeoViewController.h"
#import "ARRotatingViewController.h"
#import "ARradarViewController.h"
#import "ARDetailViewController.h"

@protocol OverlayViewControllerDelegate 

// Hace salir de la vista de RA
- (void)exitRAView;
// Obtiene el detalle de una vista giratoria pulsada
- (ARDetailViewController *)detailForCoordinate:(ARCoordinate *)coordinate;

@end


@interface OverlayViewController : ARGeoViewController  {
@private
	
	// Boton de volver
	UIButton *backButton_;
	
	ARradarViewController *radarController_;
	ARDetailViewController *tagDetail_;
	
	NSMutableArray * resultTable_;
	BOOL radarHidden_;
	BOOL isShowingLandscapeView_;
	
	NSInteger tagSelected_;
	
	id<OverlayViewControllerDelegate> overlayDelegate_;
	
	CLLocation * myLocation_;
	
}

@property (nonatomic) NSInteger tagSelected;
@property (nonatomic, assign) id<OverlayViewControllerDelegate> overlayDelegate;

- (id)initWithImagePicker:(UIImagePickerController*)picker;
- (id)initWithImagePicker:(UIImagePickerController*)picker AndLocationMan:(CLLocationManager *)manager;

// Carga en la vista de RA una lista de puntos que sigue el protocolo AugmentedRealityDataModelAccess
- (void)loadDataModelAccessArray:(NSArray*)resultTable maximumTags:(NSInteger)numberOfTags;
// Cambia la inclinacion del visor
- (BOOL)changeInclination:(BOOL)ARloaded;
// Cambia los puntos del radar girando la vista que los contiene
- (void)changeRadarsPointsPosition:(double)myazimuth;
// Resetea el radar
- (void)resetRadar;
// Devuelve el nombre del tag seleccionado
- (NSString*)getVectorName;
// Devuelve la distancia del vector seleccionado
- (NSString*)getVectorDistance;
- (BOOL)IsOrientedActived;
// Muestra u oculta la vista detalle
- (void)showHideDetailView:(BOOL)show;
- (BOOL)GetLandscapeCondition;

- (void)getRadarAndBackButtonToTheFront;

@end
